import request from '@/utils/request'

// 查询题库科目列表
export function listQbmsSubject(query) {
  return request({
    url: '/qbms/qbmsSubject/list',
    method: 'get',
    params: query
  })
}

// 查询题库科目树结构选项
export function treeselectQbmsSubject(query) {
  return request({
    url: '/qbms/qbmsSubject/treeselect',
    method: 'get',
    params: query
  })
}

// 查询题库科目详细
export function getQbmsSubject(id) {
  return request({
    url: '/qbms/qbmsSubject/' + id,
    method: 'get'
  })
}

// 新增题库科目
export function addQbmsSubject(data) {
  return request({
    url: '/qbms/qbmsSubject',
    method: 'post',
    data: data
  })
}

// 修改题库科目
export function updateQbmsSubject(data) {
  return request({
    url: '/qbms/qbmsSubject',
    method: 'put',
    data: data
  })
}

// 删除题库科目
export function delQbmsSubject(id) {
  return request({
    url: '/qbms/qbmsSubject/' + id,
    method: 'delete'
  })
}
